package extend;

public class ZooTest1 extends Zoo{
    public String carnvorous;// 肉食
    public void tiger(){
        System.out.println("老虎胡很凶！");
    }
    public void lion(){
        System.out.println("狮子头很大！");
    }
    public static void main(String[] args){
        Zoo p=new Zoo();
        p.setWeight(123.45);
        p.getWeight();
        p.move();
        System.out.println("体重："+p.getWeight());

        ZooTest1 p1=new ZooTest1();
        p1.carnvorous="食肉动物";
        p1.tiger();
        p1.lion();
        System.out.println(p1.carnvorous);
    }
}
